<template>
    <div>
        首页
        <router-link to="/user/login">登录</router-link>
        <router-link to="/user/login_two">登录2</router-link>
        <el-button @click.native="updatePasswordHandle()">修改密码</el-button>
        <!-- 弹窗, 修改密码 -->
        <update-password v-if="updatePassowrdVisible" ref="updatePassowrd"></update-password>
    </div>
</template>

<script>
import UpdatePassword from './components/update-password'
export default {
    data () {
      return {
        updatePassowrdVisible: false
      }
    },
    components: {
      UpdatePassword
    },
    methods: {
        updatePasswordHandle () {
        this.updatePassowrdVisible = true
        this.$nextTick(() => {
          this.$refs.updatePassowrd.init()
        })
      }
    }
}
</script>
